home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Utilities / Programming / Dialog Director 0.6 / Examples / Progress 2.as < prev    next >
Encoding:
Text File  |  1997-04-15  |  544 b   |  17 lines  |  [TEXT/ToyS]

  1. property theMax : 1234000
  2. dd install with greyscale
  3. set p to dd make dialog {size:[300, 50], contents:[¬
  4.     {class:static text, bounds:[8, 4, 160, 20], contents:"Thinking…"}, ¬
  5.     {class:static text, bounds:[170, 4, 288, 20], contents:"", justification:right}, ¬
  6.     {class:gauge, bounds:[10, 25, 290, 25 + 12], value:0, max value:theMax} ¬
  7.         ]}
  8. set n to 1
  9. set x to 1
  10. repeat while n < theMax
  11.     dd set value of item 3 of p to n
  12.     set n to n + x
  13.     set x to x + 1
  14.     if x mod 50 = 2 then dd set contents of item 2 of p to n
  15. end repeat
  16. dd delete p
  17. dd uninstall